
var mongoose = require('mongoose');
var Schema = mongoose.Schema;


//存储因为对方断线，而没有emit出去的消息
var UnReadMsgs= new Schema({
    to_uid:Number,
    msg_ids:Object,    //{gid:[mid,mid,mid], gid:[mid,mid,mid], from_uid:[mid,mid]}
    time:String,
    unRead:{
        type:Number,
        default:1
    }
});


var UnReadMsgs = mongoose.model('UnReadMsgs', UnReadMsgs)

module.exports = UnReadMsgs;